#pragma once

#include <gpiod.h>
#include <vector>
#include <string>
#include <chrono>
#include <thread>

#include <stdio.h>
#include <unistd.h>
#include <libserialport.h>

#include <iostream>
#include "rs485_v3.hpp"
#include "yj_return.hpp"
#include "config.h"

typedef struct
{
    float X_accel;
    float Y_accel;
    float Z_accel;
}vs_rea_xx_data_t,*Pvs_rea_xx_data_t;


yj_return vs_rea_xx_init(void);
void vs_rea_xx_deinit(void);
yj_return vs_rea_xx_read_all(vs_rea_xx_data_t *data);
void vs_rea_xx_print_data(vs_rea_xx_data_t *data);